import request from '@/common/request.js';

// 获取分类
export const queryAllClasses = data => {
	return request.get({
		url: '/tube/wa/queryAllClasses',
		data: data
	});
}

//获取商品详情信息
export const queryProductDetail = data => {
	return request.get({
		url: '/tube/wa/detailProduct',
		data: data
	});
}

//获取全部商品信息
export const queryAllProducts = data => {
	return request.get({
		url: '/tube/admin/queryProducts',
		data: data
	});
}

//加入购物车
export const createShoppingCart = data => {
	return request.post({
		url: '/tube/user/createShopping',
		data: data
	});
}

//预结算商品查询
export const queryJiesProducts = data => {
	return request.post({
		url: '/tube/user/queryJiesProducts',
		data: data
	});
}



// 创建预订单
export const createOrdersApi = data => {
	return request.post({
		url: '/tube/user/createOrders',
		data: data,
	});
}

//查询用户默认地址
export const queryDefAddrApi = data => {
	return request.get({
		url: '/tube/user/queryDefAddr',
		data: data
	});
}
